<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <script src="https://cdn.bootcdn.net/ajax/libs/jquery/3.6.0/jquery.js"></script>
    <style>
                * {
            padding: 0;
            margin: 0;
        }

        .container {
            text-align: center;
            position: relative;
        }

        .img {
            position: relative;
            margin: 20px auto;
            width: 500px
        }

        .img>div {
            position: absolute;
        }

        .img img {
            width: 500px;
        }

        .img div:nth-child(1) {
            z-index: 10;
        }
        ul{
            position: absolute;
            top: 200px;
            left: 620px;
            
        }
        ul>li {
            
            width: 8px;
            height: 8px;
            border-radius: 50%;
            background: #6D6863;
            display: inline-block;
            margin-left: 10px;
            border: 2px solid #B0B0B0;
            list-style: none;
            cursor: pointer;
        }

        ul .active {
            background: white;
            border: 2px solid #6D6863;
           
        }
    </style>
</head>
<body>
    
        <div class="container">
            <ul>
                <li class="active"></li>
                <li></li>
                <li></li>
                <li></li>
            </ul>
        </div>
        <div class="img">
            <div><img src="images/adv2.jpg" alt=""></div>
            <div><img src="images/adv3.jpg" alt=""></div>
            <div><img src="images/adv4.jpg" alt=""></div>
            <div><img src="images/adv5.jpg" alt=""></div>
        </div>
    <script>
        $("ul li").click(function(){
            $(this).addClass("active").siblings().removeClass("active");
            var index = $(this).index();
            $(".img div").eq(index).css({display:"block"}).siblings().css({display:"none"});
            //$(".img div").eq(index).show().siblings().hide();
        })
    </script>
</body>
</html>